﻿using AngryManagementMayhem.Content.Map.TestMapScreens;
using AngryManagementMayhem.Content.Textures.Character;
using AngryManagementMayhem.Content.Textures.Map;
using AngryManagementMayhem.Controller.Map;
using AngryManagementMayhem.Controller.Player;
using AngryManagementMayhem.Controller.Player.Input;
using Transformable_Engine_v2.Engine.Input;
using Transformable_Engine_v2.Engine.Transformable_Math.Geometry;

namespace AngryManagementMayhem.Content.Map
{
    public class TestMap : BaseMap
    {
        public override void LoadContent()
        {
            TestMapSpriteSheet.LoadContent();

            AddScreen(0, 0, new TestScreen00());

            var playerContainer = new BaseScreen();

            InputManager manager1 = new InputManager(KeyboardInput.Key.JoystickMZ, KeyboardInput.Key.JoystickZ, KeyboardInput.Key.JoystickMX, KeyboardInput.Key.JoystickX,
                                                    KeyboardInput.Key.GamepadButton0, KeyboardInput.Key.GamepadButton3, KeyboardInput.Key.GamepadButton1, KeyboardInput.Key.GamepadButton2, 
                                                    KeyboardInput.Key.GamepadButton5, KeyboardInput.Key.JoystickMY, KeyboardInput.Key.GamepadButton4, KeyboardInput.Key.JoystickY)
                {
                    GamepadId = 0
                };

            InputManager manager2 = new InputManager(KeyboardInput.Key.W, KeyboardInput.Key.S, KeyboardInput.Key.A, KeyboardInput.Key.D,
                                                    KeyboardInput.Key.K, KeyboardInput.Key.I, KeyboardInput.Key.L, KeyboardInput.Key.J, 
                                                    KeyboardInput.Key.O, KeyboardInput.Key.Num9, KeyboardInput.Key.U, KeyboardInput.Key.Num7)
                {
                    GamepadId = 0
                };

            playerContainer.AddChildren(new TestCharacter(new TE_Vector2(26, 9), manager1));
            playerContainer.AddChildren(new TestCharacter(new TE_Vector2(15, 9), manager2));
            AddChildren(BackParticleScreen, playerContainer, FrontParticleScreen, ProjectileScreen);

            base.LoadContent();
        }
    }
}